package com.gla.giliair.entity;

import java.math.BigDecimal;
import java.util.ArrayList;
import java.util.Date;
import java.util.List;

public class DiscountExample {
    protected String orderByClause;

    protected boolean distinct;

    protected List<Criteria> oredCriteria;

    private Integer limit;

    private Long offset;

    public DiscountExample() {
        oredCriteria = new ArrayList<>();
    }

    public void setOrderByClause(String orderByClause) {
        this.orderByClause = orderByClause;
    }

    public String getOrderByClause() {
        return orderByClause;
    }

    public void setDistinct(boolean distinct) {
        this.distinct = distinct;
    }

    public boolean isDistinct() {
        return distinct;
    }

    public List<Criteria> getOredCriteria() {
        return oredCriteria;
    }

    public void or(Criteria criteria) {
        oredCriteria.add(criteria);
    }

    public Criteria or() {
        Criteria criteria = createCriteriaInternal();
        oredCriteria.add(criteria);
        return criteria;
    }

    public Criteria createCriteria() {
        Criteria criteria = createCriteriaInternal();
        if (oredCriteria.size() == 0) {
            oredCriteria.add(criteria);
        }
        return criteria;
    }

    protected Criteria createCriteriaInternal() {
        Criteria criteria = new Criteria();
        return criteria;
    }

    public void clear() {
        oredCriteria.clear();
        orderByClause = null;
        distinct = false;
    }

    public void setLimit(Integer limit) {
        this.limit = limit;
    }

    public Integer getLimit() {
        return limit;
    }

    public void setOffset(Long offset) {
        this.offset = offset;
    }

    public Long getOffset() {
        return offset;
    }

    protected abstract static class GeneratedCriteria {
        protected List<Criterion> criteria;

        protected GeneratedCriteria() {
            super();
            criteria = new ArrayList<>();
        }

        public boolean isValid() {
            return criteria.size() > 0;
        }

        public List<Criterion> getAllCriteria() {
            return criteria;
        }

        public List<Criterion> getCriteria() {
            return criteria;
        }

        protected void addCriterion(String condition) {
            if (condition == null) {
                throw new RuntimeException("Value for condition cannot be null");
            }
            criteria.add(new Criterion(condition));
        }

        protected void addCriterion(String condition, Object value, String property) {
            if (value == null) {
                throw new RuntimeException("Value for " + property + " cannot be null");
            }
            criteria.add(new Criterion(condition, value));
        }

        protected void addCriterion(String condition, Object value1, Object value2, String property) {
            if (value1 == null || value2 == null) {
                throw new RuntimeException("Between values for " + property + " cannot be null");
            }
            criteria.add(new Criterion(condition, value1, value2));
        }

        public Criteria andDiscountIdIsNull() {
            addCriterion("discount_id is null");
            return (Criteria) this;
        }

        public Criteria andDiscountIdIsNotNull() {
            addCriterion("discount_id is not null");
            return (Criteria) this;
        }

        public Criteria andDiscountIdEqualTo(Long value) {
            addCriterion("discount_id =", value, "discountId");
            return (Criteria) this;
        }

        public Criteria andDiscountIdNotEqualTo(Long value) {
            addCriterion("discount_id <>", value, "discountId");
            return (Criteria) this;
        }

        public Criteria andDiscountIdGreaterThan(Long value) {
            addCriterion("discount_id >", value, "discountId");
            return (Criteria) this;
        }

        public Criteria andDiscountIdGreaterThanOrEqualTo(Long value) {
            addCriterion("discount_id >=", value, "discountId");
            return (Criteria) this;
        }

        public Criteria andDiscountIdLessThan(Long value) {
            addCriterion("discount_id <", value, "discountId");
            return (Criteria) this;
        }

        public Criteria andDiscountIdLessThanOrEqualTo(Long value) {
            addCriterion("discount_id <=", value, "discountId");
            return (Criteria) this;
        }

        public Criteria andDiscountIdIn(List<Long> values) {
            addCriterion("discount_id in", values, "discountId");
            return (Criteria) this;
        }

        public Criteria andDiscountIdNotIn(List<Long> values) {
            addCriterion("discount_id not in", values, "discountId");
            return (Criteria) this;
        }

        public Criteria andDiscountIdBetween(Long value1, Long value2) {
            addCriterion("discount_id between", value1, value2, "discountId");
            return (Criteria) this;
        }

        public Criteria andDiscountIdNotBetween(Long value1, Long value2) {
            addCriterion("discount_id not between", value1, value2, "discountId");
            return (Criteria) this;
        }

        public Criteria andCompanyIdIsNull() {
            addCriterion("company_id is null");
            return (Criteria) this;
        }

        public Criteria andCompanyIdIsNotNull() {
            addCriterion("company_id is not null");
            return (Criteria) this;
        }

        public Criteria andCompanyIdEqualTo(Long value) {
            addCriterion("company_id =", value, "companyId");
            return (Criteria) this;
        }

        public Criteria andCompanyIdNotEqualTo(Long value) {
            addCriterion("company_id <>", value, "companyId");
            return (Criteria) this;
        }

        public Criteria andCompanyIdGreaterThan(Long value) {
            addCriterion("company_id >", value, "companyId");
            return (Criteria) this;
        }

        public Criteria andCompanyIdGreaterThanOrEqualTo(Long value) {
            addCriterion("company_id >=", value, "companyId");
            return (Criteria) this;
        }

        public Criteria andCompanyIdLessThan(Long value) {
            addCriterion("company_id <", value, "companyId");
            return (Criteria) this;
        }

        public Criteria andCompanyIdLessThanOrEqualTo(Long value) {
            addCriterion("company_id <=", value, "companyId");
            return (Criteria) this;
        }

        public Criteria andCompanyIdIn(List<Long> values) {
            addCriterion("company_id in", values, "companyId");
            return (Criteria) this;
        }

        public Criteria andCompanyIdNotIn(List<Long> values) {
            addCriterion("company_id not in", values, "companyId");
            return (Criteria) this;
        }

        public Criteria andCompanyIdBetween(Long value1, Long value2) {
            addCriterion("company_id between", value1, value2, "companyId");
            return (Criteria) this;
        }

        public Criteria andCompanyIdNotBetween(Long value1, Long value2) {
            addCriterion("company_id not between", value1, value2, "companyId");
            return (Criteria) this;
        }

        public Criteria andAdultDiscountIsNull() {
            addCriterion("adult_discount is null");
            return (Criteria) this;
        }

        public Criteria andAdultDiscountIsNotNull() {
            addCriterion("adult_discount is not null");
            return (Criteria) this;
        }

        public Criteria andAdultDiscountEqualTo(BigDecimal value) {
            addCriterion("adult_discount =", value, "adultDiscount");
            return (Criteria) this;
        }

        public Criteria andAdultDiscountNotEqualTo(BigDecimal value) {
            addCriterion("adult_discount <>", value, "adultDiscount");
            return (Criteria) this;
        }

        public Criteria andAdultDiscountGreaterThan(BigDecimal value) {
            addCriterion("adult_discount >", value, "adultDiscount");
            return (Criteria) this;
        }

        public Criteria andAdultDiscountGreaterThanOrEqualTo(BigDecimal value) {
            addCriterion("adult_discount >=", value, "adultDiscount");
            return (Criteria) this;
        }

        public Criteria andAdultDiscountLessThan(BigDecimal value) {
            addCriterion("adult_discount <", value, "adultDiscount");
            return (Criteria) this;
        }

        public Criteria andAdultDiscountLessThanOrEqualTo(BigDecimal value) {
            addCriterion("adult_discount <=", value, "adultDiscount");
            return (Criteria) this;
        }

        public Criteria andAdultDiscountIn(List<BigDecimal> values) {
            addCriterion("adult_discount in", values, "adultDiscount");
            return (Criteria) this;
        }

        public Criteria andAdultDiscountNotIn(List<BigDecimal> values) {
            addCriterion("adult_discount not in", values, "adultDiscount");
            return (Criteria) this;
        }

        public Criteria andAdultDiscountBetween(BigDecimal value1, BigDecimal value2) {
            addCriterion("adult_discount between", value1, value2, "adultDiscount");
            return (Criteria) this;
        }

        public Criteria andAdultDiscountNotBetween(BigDecimal value1, BigDecimal value2) {
            addCriterion("adult_discount not between", value1, value2, "adultDiscount");
            return (Criteria) this;
        }

        public Criteria andChildrenDiscountIsNull() {
            addCriterion("children_discount is null");
            return (Criteria) this;
        }

        public Criteria andChildrenDiscountIsNotNull() {
            addCriterion("children_discount is not null");
            return (Criteria) this;
        }

        public Criteria andChildrenDiscountEqualTo(BigDecimal value) {
            addCriterion("children_discount =", value, "childrenDiscount");
            return (Criteria) this;
        }

        public Criteria andChildrenDiscountNotEqualTo(BigDecimal value) {
            addCriterion("children_discount <>", value, "childrenDiscount");
            return (Criteria) this;
        }

        public Criteria andChildrenDiscountGreaterThan(BigDecimal value) {
            addCriterion("children_discount >", value, "childrenDiscount");
            return (Criteria) this;
        }

        public Criteria andChildrenDiscountGreaterThanOrEqualTo(BigDecimal value) {
            addCriterion("children_discount >=", value, "childrenDiscount");
            return (Criteria) this;
        }

        public Criteria andChildrenDiscountLessThan(BigDecimal value) {
            addCriterion("children_discount <", value, "childrenDiscount");
            return (Criteria) this;
        }

        public Criteria andChildrenDiscountLessThanOrEqualTo(BigDecimal value) {
            addCriterion("children_discount <=", value, "childrenDiscount");
            return (Criteria) this;
        }

        public Criteria andChildrenDiscountIn(List<BigDecimal> values) {
            addCriterion("children_discount in", values, "childrenDiscount");
            return (Criteria) this;
        }

        public Criteria andChildrenDiscountNotIn(List<BigDecimal> values) {
            addCriterion("children_discount not in", values, "childrenDiscount");
            return (Criteria) this;
        }

        public Criteria andChildrenDiscountBetween(BigDecimal value1, BigDecimal value2) {
            addCriterion("children_discount between", value1, value2, "childrenDiscount");
            return (Criteria) this;
        }

        public Criteria andChildrenDiscountNotBetween(BigDecimal value1, BigDecimal value2) {
            addCriterion("children_discount not between", value1, value2, "childrenDiscount");
            return (Criteria) this;
        }

        public Criteria andNormalDiscountIsNull() {
            addCriterion("normal_discount is null");
            return (Criteria) this;
        }

        public Criteria andNormalDiscountIsNotNull() {
            addCriterion("normal_discount is not null");
            return (Criteria) this;
        }

        public Criteria andNormalDiscountEqualTo(BigDecimal value) {
            addCriterion("normal_discount =", value, "normalDiscount");
            return (Criteria) this;
        }

        public Criteria andNormalDiscountNotEqualTo(BigDecimal value) {
            addCriterion("normal_discount <>", value, "normalDiscount");
            return (Criteria) this;
        }

        public Criteria andNormalDiscountGreaterThan(BigDecimal value) {
            addCriterion("normal_discount >", value, "normalDiscount");
            return (Criteria) this;
        }

        public Criteria andNormalDiscountGreaterThanOrEqualTo(BigDecimal value) {
            addCriterion("normal_discount >=", value, "normalDiscount");
            return (Criteria) this;
        }

        public Criteria andNormalDiscountLessThan(BigDecimal value) {
            addCriterion("normal_discount <", value, "normalDiscount");
            return (Criteria) this;
        }

        public Criteria andNormalDiscountLessThanOrEqualTo(BigDecimal value) {
            addCriterion("normal_discount <=", value, "normalDiscount");
            return (Criteria) this;
        }

        public Criteria andNormalDiscountIn(List<BigDecimal> values) {
            addCriterion("normal_discount in", values, "normalDiscount");
            return (Criteria) this;
        }

        public Criteria andNormalDiscountNotIn(List<BigDecimal> values) {
            addCriterion("normal_discount not in", values, "normalDiscount");
            return (Criteria) this;
        }

        public Criteria andNormalDiscountBetween(BigDecimal value1, BigDecimal value2) {
            addCriterion("normal_discount between", value1, value2, "normalDiscount");
            return (Criteria) this;
        }

        public Criteria andNormalDiscountNotBetween(BigDecimal value1, BigDecimal value2) {
            addCriterion("normal_discount not between", value1, value2, "normalDiscount");
            return (Criteria) this;
        }

        public Criteria andSilverDiscountIsNull() {
            addCriterion("silver_discount is null");
            return (Criteria) this;
        }

        public Criteria andSilverDiscountIsNotNull() {
            addCriterion("silver_discount is not null");
            return (Criteria) this;
        }

        public Criteria andSilverDiscountEqualTo(BigDecimal value) {
            addCriterion("silver_discount =", value, "silverDiscount");
            return (Criteria) this;
        }

        public Criteria andSilverDiscountNotEqualTo(BigDecimal value) {
            addCriterion("silver_discount <>", value, "silverDiscount");
            return (Criteria) this;
        }

        public Criteria andSilverDiscountGreaterThan(BigDecimal value) {
            addCriterion("silver_discount >", value, "silverDiscount");
            return (Criteria) this;
        }

        public Criteria andSilverDiscountGreaterThanOrEqualTo(BigDecimal value) {
            addCriterion("silver_discount >=", value, "silverDiscount");
            return (Criteria) this;
        }

        public Criteria andSilverDiscountLessThan(BigDecimal value) {
            addCriterion("silver_discount <", value, "silverDiscount");
            return (Criteria) this;
        }

        public Criteria andSilverDiscountLessThanOrEqualTo(BigDecimal value) {
            addCriterion("silver_discount <=", value, "silverDiscount");
            return (Criteria) this;
        }

        public Criteria andSilverDiscountIn(List<BigDecimal> values) {
            addCriterion("silver_discount in", values, "silverDiscount");
            return (Criteria) this;
        }

        public Criteria andSilverDiscountNotIn(List<BigDecimal> values) {
            addCriterion("silver_discount not in", values, "silverDiscount");
            return (Criteria) this;
        }

        public Criteria andSilverDiscountBetween(BigDecimal value1, BigDecimal value2) {
            addCriterion("silver_discount between", value1, value2, "silverDiscount");
            return (Criteria) this;
        }

        public Criteria andSilverDiscountNotBetween(BigDecimal value1, BigDecimal value2) {
            addCriterion("silver_discount not between", value1, value2, "silverDiscount");
            return (Criteria) this;
        }

        public Criteria andGoldDiscountIsNull() {
            addCriterion("gold_discount is null");
            return (Criteria) this;
        }

        public Criteria andGoldDiscountIsNotNull() {
            addCriterion("gold_discount is not null");
            return (Criteria) this;
        }

        public Criteria andGoldDiscountEqualTo(BigDecimal value) {
            addCriterion("gold_discount =", value, "goldDiscount");
            return (Criteria) this;
        }

        public Criteria andGoldDiscountNotEqualTo(BigDecimal value) {
            addCriterion("gold_discount <>", value, "goldDiscount");
            return (Criteria) this;
        }

        public Criteria andGoldDiscountGreaterThan(BigDecimal value) {
            addCriterion("gold_discount >", value, "goldDiscount");
            return (Criteria) this;
        }

        public Criteria andGoldDiscountGreaterThanOrEqualTo(BigDecimal value) {
            addCriterion("gold_discount >=", value, "goldDiscount");
            return (Criteria) this;
        }

        public Criteria andGoldDiscountLessThan(BigDecimal value) {
            addCriterion("gold_discount <", value, "goldDiscount");
            return (Criteria) this;
        }

        public Criteria andGoldDiscountLessThanOrEqualTo(BigDecimal value) {
            addCriterion("gold_discount <=", value, "goldDiscount");
            return (Criteria) this;
        }

        public Criteria andGoldDiscountIn(List<BigDecimal> values) {
            addCriterion("gold_discount in", values, "goldDiscount");
            return (Criteria) this;
        }

        public Criteria andGoldDiscountNotIn(List<BigDecimal> values) {
            addCriterion("gold_discount not in", values, "goldDiscount");
            return (Criteria) this;
        }

        public Criteria andGoldDiscountBetween(BigDecimal value1, BigDecimal value2) {
            addCriterion("gold_discount between", value1, value2, "goldDiscount");
            return (Criteria) this;
        }

        public Criteria andGoldDiscountNotBetween(BigDecimal value1, BigDecimal value2) {
            addCriterion("gold_discount not between", value1, value2, "goldDiscount");
            return (Criteria) this;
        }

        public Criteria andCreateTimeIsNull() {
            addCriterion("create_time is null");
            return (Criteria) this;
        }

        public Criteria andCreateTimeIsNotNull() {
            addCriterion("create_time is not null");
            return (Criteria) this;
        }

        public Criteria andCreateTimeEqualTo(Date value) {
            addCriterion("create_time =", value, "createTime");
            return (Criteria) this;
        }

        public Criteria andCreateTimeNotEqualTo(Date value) {
            addCriterion("create_time <>", value, "createTime");
            return (Criteria) this;
        }

        public Criteria andCreateTimeGreaterThan(Date value) {
            addCriterion("create_time >", value, "createTime");
            return (Criteria) this;
        }

        public Criteria andCreateTimeGreaterThanOrEqualTo(Date value) {
            addCriterion("create_time >=", value, "createTime");
            return (Criteria) this;
        }

        public Criteria andCreateTimeLessThan(Date value) {
            addCriterion("create_time <", value, "createTime");
            return (Criteria) this;
        }

        public Criteria andCreateTimeLessThanOrEqualTo(Date value) {
            addCriterion("create_time <=", value, "createTime");
            return (Criteria) this;
        }

        public Criteria andCreateTimeIn(List<Date> values) {
            addCriterion("create_time in", values, "createTime");
            return (Criteria) this;
        }

        public Criteria andCreateTimeNotIn(List<Date> values) {
            addCriterion("create_time not in", values, "createTime");
            return (Criteria) this;
        }

        public Criteria andCreateTimeBetween(Date value1, Date value2) {
            addCriterion("create_time between", value1, value2, "createTime");
            return (Criteria) this;
        }

        public Criteria andCreateTimeNotBetween(Date value1, Date value2) {
            addCriterion("create_time not between", value1, value2, "createTime");
            return (Criteria) this;
        }

        public Criteria andUpdateTimeIsNull() {
            addCriterion("update_time is null");
            return (Criteria) this;
        }

        public Criteria andUpdateTimeIsNotNull() {
            addCriterion("update_time is not null");
            return (Criteria) this;
        }

        public Criteria andUpdateTimeEqualTo(Date value) {
            addCriterion("update_time =", value, "updateTime");
            return (Criteria) this;
        }

        public Criteria andUpdateTimeNotEqualTo(Date value) {
            addCriterion("update_time <>", value, "updateTime");
            return (Criteria) this;
        }

        public Criteria andUpdateTimeGreaterThan(Date value) {
            addCriterion("update_time >", value, "updateTime");
            return (Criteria) this;
        }

        public Criteria andUpdateTimeGreaterThanOrEqualTo(Date value) {
            addCriterion("update_time >=", value, "updateTime");
            return (Criteria) this;
        }

        public Criteria andUpdateTimeLessThan(Date value) {
            addCriterion("update_time <", value, "updateTime");
            return (Criteria) this;
        }

        public Criteria andUpdateTimeLessThanOrEqualTo(Date value) {
            addCriterion("update_time <=", value, "updateTime");
            return (Criteria) this;
        }

        public Criteria andUpdateTimeIn(List<Date> values) {
            addCriterion("update_time in", values, "updateTime");
            return (Criteria) this;
        }

        public Criteria andUpdateTimeNotIn(List<Date> values) {
            addCriterion("update_time not in", values, "updateTime");
            return (Criteria) this;
        }

        public Criteria andUpdateTimeBetween(Date value1, Date value2) {
            addCriterion("update_time between", value1, value2, "updateTime");
            return (Criteria) this;
        }

        public Criteria andUpdateTimeNotBetween(Date value1, Date value2) {
            addCriterion("update_time not between", value1, value2, "updateTime");
            return (Criteria) this;
        }

        public Criteria andIsDeletedIsNull() {
            addCriterion("is_deleted is null");
            return (Criteria) this;
        }

        public Criteria andIsDeletedIsNotNull() {
            addCriterion("is_deleted is not null");
            return (Criteria) this;
        }

        public Criteria andIsDeletedEqualTo(Integer value) {
            addCriterion("is_deleted =", value, "isDeleted");
            return (Criteria) this;
        }

        public Criteria andIsDeletedNotEqualTo(Integer value) {
            addCriterion("is_deleted <>", value, "isDeleted");
            return (Criteria) this;
        }

        public Criteria andIsDeletedGreaterThan(Integer value) {
            addCriterion("is_deleted >", value, "isDeleted");
            return (Criteria) this;
        }

        public Criteria andIsDeletedGreaterThanOrEqualTo(Integer value) {
            addCriterion("is_deleted >=", value, "isDeleted");
            return (Criteria) this;
        }

        public Criteria andIsDeletedLessThan(Integer value) {
            addCriterion("is_deleted <", value, "isDeleted");
            return (Criteria) this;
        }

        public Criteria andIsDeletedLessThanOrEqualTo(Integer value) {
            addCriterion("is_deleted <=", value, "isDeleted");
            return (Criteria) this;
        }

        public Criteria andIsDeletedIn(List<Integer> values) {
            addCriterion("is_deleted in", values, "isDeleted");
            return (Criteria) this;
        }

        public Criteria andIsDeletedNotIn(List<Integer> values) {
            addCriterion("is_deleted not in", values, "isDeleted");
            return (Criteria) this;
        }

        public Criteria andIsDeletedBetween(Integer value1, Integer value2) {
            addCriterion("is_deleted between", value1, value2, "isDeleted");
            return (Criteria) this;
        }

        public Criteria andIsDeletedNotBetween(Integer value1, Integer value2) {
            addCriterion("is_deleted not between", value1, value2, "isDeleted");
            return (Criteria) this;
        }
    }

    /**
     */
    public static class Criteria extends GeneratedCriteria {
        protected Criteria() {
            super();
        }
    }

    public static class Criterion {
        private String condition;

        private Object value;

        private Object secondValue;

        private boolean noValue;

        private boolean singleValue;

        private boolean betweenValue;

        private boolean listValue;

        private String typeHandler;

        public String getCondition() {
            return condition;
        }

        public Object getValue() {
            return value;
        }

        public Object getSecondValue() {
            return secondValue;
        }

        public boolean isNoValue() {
            return noValue;
        }

        public boolean isSingleValue() {
            return singleValue;
        }

        public boolean isBetweenValue() {
            return betweenValue;
        }

        public boolean isListValue() {
            return listValue;
        }

        public String getTypeHandler() {
            return typeHandler;
        }

        protected Criterion(String condition) {
            super();
            this.condition = condition;
            this.typeHandler = null;
            this.noValue = true;
        }

        protected Criterion(String condition, Object value, String typeHandler) {
            super();
            this.condition = condition;
            this.value = value;
            this.typeHandler = typeHandler;
            if (value instanceof List<?>) {
                this.listValue = true;
            } else {
                this.singleValue = true;
            }
        }

        protected Criterion(String condition, Object value) {
            this(condition, value, null);
        }

        protected Criterion(String condition, Object value, Object secondValue, String typeHandler) {
            super();
            this.condition = condition;
            this.value = value;
            this.secondValue = secondValue;
            this.typeHandler = typeHandler;
            this.betweenValue = true;
        }

        protected Criterion(String condition, Object value, Object secondValue) {
            this(condition, value, secondValue, null);
        }
    }
}